Component({
  properties: {
    imagePathList: {
      type: Array,
      value: [],
    }
  },
  observers: {
    'imagePathList': function(data) {
      let result = [];
      if (data.length < 3) {
        result = data[0];
      } else {
        result = data.filter((item, index) => index < 3)
      }

      this.setData({
        imageArray: result
      })
    }
  },

  data() {
    imageArray: []
  }
})
